home *** CD-ROM | disk | FTP | other *** search
- Path: itnews.sc.intel.com!news
- From: Eric Minor <EricX_Minor@ccm.sc.intel.com>
- Newsgroups: comp.lang.c++
- Subject: VC++ 4.0 question and rantings
- Date: 4 Jan 1996 01:26:36 GMT
- Organization: Intel - Internet Engineering Group
- Message-ID: <4cfacc$m8b@itnews.sc.intel.com>
- NNTP-Posting-Host: eminorx-desk.sc.intel.com
-
-
-
- IÆm a fairly new user to Microsoft Visual C++ (ver 4.0) and am
- running into a few stumbling blocks. However, I am an experienced
- C++ developer, having used BorlandÆs product (ver 4.5).
-
- Before getting to the question, a bit of background about my
- philosophy is important I think. I prefer not to use the code
- generating tools that come with both BorlandÆs and MicrosoftÆs
- compilers (app and class expert for Borland; app and class wizard
- for Microsoft). I donÆt mind using these smart tools as a
- learning tool to generate some sample code which I can then study
- in order to learn the app frameworkÆs that come with these products.
- However, I do not want to use them for the production applications
- that I write for my clients for the following reasons (among others).
-
- 1) Relying on the wizards to generate the code removes me too
- far from the knowledge of what is making the code run.
- Some human needs to understand the inner workings of the
- underlying code otherwise any decent sized project becomes an
- unmaintainable morass of mystery code (IMO). (Sidebar: ThatÆs
- kind of my complaint against 4GL tools also: Do they abstract
- the developer too far away from the knowledge of what lies
- beneath? And no I donÆt recommend going back to assembler :^) )
-
- 2) I like my code clean and neat. If you use wizards, they must
- necessarily junk up the code with extraneous commenting that
- helps them to keep track of everything (sections for handler
- functions, virtual functions, etc.)
-
- 3) As a matter of principle, the C++ code that comprises my project
- (along with the various resource files, def files, custom
- controls, etc.) should be largely self-supporting and independent
- of the particular compiler. Granted, this is never 100% true
- and some migration issues will always need to be addressed.
- Certainly, use of the application frameworks of either compiler
- (OWL or MFC) will tend to tie you to that particular product.
- But in theory, we should be able to migrate these entire class
- hierarchies to another environment and recompile them there (not
- that IÆd want to) along with the rest of the project. However,
- relying on wizards throws any semblance of portability right out
- the window. The little commenting schemes and methods of
- operation of the wizards and experts are totally proprietary and
- tie you completely to a particular product.
-
- 4) I donÆt find the point and click interface of the class wizard
- to be any improvement or simplification over a simple text
- editor. WhatÆs so hard about going to your class definition
- and adding a member variable or function? WhatÆs so hard about
- cutting and pasting a new function into your implementation file?
- I find unneeded user interfaces for these simple tasks to be a
- hindrance rather than a help. And again, I assert that this
- added layer of interface tends to prevent the novice C++
- developer from really comprehending what is going on in the code.
-
- I could go on, but you get the picture. With that said, I donÆt
- object to having wizards included in these products for those that
- find them useful. However, please donÆt throw up roadblocks for me
- if I choose not to use them, which is what I seem to be finding.
-
- Whether you agree with my philosophy or not, here is the problem I
- am running into. I have chosen to create my project from scratch
- without using the app wizard or class wizard, but it keeps trying
- to drag me back in. I have a simple MDI application that is compiling and running just
- fine. Now I need to start using the grid OLE control (.OCX) that
- came bundled with the development environment.
-
- The instructions for performing this task are laid out in the
- online doco and are straight-forward. Just select Insert...component
- off the main menu which takes you to component gallery and then
- select the particular control you want to use. When I follow these
- steps in an app wizard generated project, it works just fine and
- adds the control to the dialog editorÆs palette and also creates
- header and implementation files for three wrapper classes. When
- I try to do this in my real non-app wizard project (the one I get
- paid for), it barfs up the following error message.
-
- "The ClassWizard database does not exist and there are no resource
- files associated with this project to build one from. In order to
- continue add a resource script to the project."
-
- Regarding the message, I do indeed have a resource script included
- in the project. No, IÆm not using class wizard so I donÆt suppose
- there is a ClassWizard database. Will this prevent me from ever
- using a third party OCX control?
-
- Any helpful information about my primary problem will be appreciated.
- Also, IÆd be interested to hear any thoughts regarding my rantings
- about wizards and about the product (VC++ 4.0) in general.
-
- Thanks,
-
- Eric Minor
-
-